import { createPinia } from 'pinia'
import persist from 'pinia-plugin-persistedstate'

// TODO 从子目录中导入 store 模块
import { usePlayerStore } from './modules/media/player'
import { useMusicStore } from './modules/media/music'
import { usePlaylistStore } from './modules/media/playlist'
import { useAuthStore } from './modules/user/auth'
import { useUserProfileStore } from './modules/user/profile'

const pinia = createPinia()
pinia.use(persist)

export default pinia

// TODO 导出所有 store
export {
  usePlayerStore,
  useMusicStore,
  usePlaylistStore,
  useAuthStore,
  useUserProfileStore
}
